package com.drink.yan.job;

import com.drink.yan.intf.define.YanTaskStatusE;
import com.drink.yan.intf.entity.YanUserDetail;
import com.drink.yan.intf.entity.YanUserTeacher;
import com.drink.yan.intf.vo.TaskVo;
import com.drink.yan.svc.service.YanTaskService;
import com.drink.yan.svc.service.YanUserService;
import com.drink.yan.web.rest.req.qry.PageTaskQry;
import com.drink.yan.web.rest.req.qry.PageTeacherQry;
import com.google.common.collect.Lists;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 定时任务，计算活动状态
 *
 * @Title:
 * @Package: com.drink.yan.job.
 * @Author: M.simple
 * @Remark: The modified content
 * @CreateDate: 2023-12-18 12:12
 * @Version: v2.0
 */
@Slf4j
@Component("YanUserDataAuthParseJob")
public class YanUserDataAuthParseJob {

	@Resource
	private YanUserService yanUserService;

	public void handle(){

		log.info("===========start YanTaskStatusJob===========");

		List<YanUserDetail> yanUserTeachers = yanUserService.listTeacherDataNeedParse();
		yanUserTeachers.forEach(x->{
			yanUserService.dataAuthParse(x);
		});
	}
}
